package middleware

import (
	"github.com/gin-gonic/gin"
)

type APIResponse struct {
	Code    string `json:"code"`
	Message string `json:"message"`
	Data    interface {
	} `json:"data"`
	Success bool `json:"success"`
}

// ResponseJSON 返回格式定义
func ResponseJSON(c *gin.Context, httpCode int, resp APIResponse) {
	c.JSON(httpCode, resp)
}
